package com.un.ebs.sys.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.un.ebs.sys.domain.UserPowerExt;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;
import org.springframework.stereotype.Component;

/**
 * <p>
 * 2 Mapper 接口
 * </p>
 *
 * @author liubo
 * @since 2019-10-12
 */
@Component
public interface UserPowerExtMapper extends BaseMapper<UserPowerExt> {
    @Select("select isnull(max(sort)+1,1) from v_user_power_ext where parent_id=#{parentId}")
    int maxSortByParentId(@Param("parentId") String parentId);

}
